<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>空间</title>
    {load href="__static__/home/css/bootstrap.min.css" /}
    {load href="__static__/home/css/header.css" /}
    {load href="__static__/home/css/journal.css" /}

</head>
<body>
    <div class="box_body">
        {include file='public/header' /}

        <div class="main_body">
            <div class="main">
                <div class="main_title">
                    <ul class="main_nav">
                        <li><span id="rz" class="main_bd">我的日志</span></li>
                        <li><span id="rj" class="">私密日记</span></li>
                    </ul>
                </div>
                <!-- 我的日志开始 -->
                <div class="main_box" style="" id="myrz">
                    <div class="main_left">
                        <div class="main_left_top">
                            <a href="{:url('journal/jouadd',['name'=>'log'])}"><div class="main_btn">写日志</div></a>
                            <span style="float:right;margin-top:-25px;">发表时间</span>
                        </div>
                        <div class="main_left_bd">
                            <ul class="main_left_nav">
                                {volist name="logdata" id="vo"}
                                <li>
                                    <p></p>
                                    <a href="{:url('journal/journalinfo',['name'=>'log','id' =>$vo.id])}" class="c">{$vo.title}</a>
                                    <a href="{:url('journal/joudel',['name'=>'log','id'=>$vo.id])}" style="float:right;text-align:center;">删除</a>
                                    <span style="float:right">&nbsp;|&nbsp;</span>
                                    <a href="{:url('journal/jouedit',['name'=>'log','id'=>$vo.id])}" style="float:right;text-align:center;">编辑</a>
                                    <span class="main_time">
                                        <?php echo date("Y-m-d",$vo['add_time']);?>
                                    </span>
                                </li>
                                {/volist}
                            </ul>
                        </div>
                    </div><!-- main_left  end -->
                    <div class="main_right">
                        <div class="main_right_top">
                            <div class="main_right_hd">日志分类<a href="">管理</a></div>
                            <div class="main_right_bd">
                                <ul class="bd_nav">
                                    <li><a>全部日志<span>({$lcdata})</span></a></li>
                                    <li><a>个人日记<span>({$dcdata})</span></a></li>
                                </ul>
                            </div>
                        </div>
                    </div>
                </div><!-- main_box  end -->
                <!-- 我的日志结束 -->

                <!-- 私密日记开始 -->
                <div class="main_box" id="myrj" style="display:none">
                    <div class="main_left">
                        <div class="main_left_top">
                            <a href="{:url('journal/jouradd',['name'=>'diary'])}"><div class="main_btn">写私密日记</div></a>
                        </div>
                        <div class="main_left_bd">
                            <div class="smrj">私密日记 <span>共有 {$dcdata} 篇</span></div>
                            <ul class="main_left_nav">
                                {volist name="diarydata" id="vo"}
                                <li>
                                    <a href="{:url('journal/journalinfo',['name'=>'diary','id'=>$vo.id])}" class="c">{$vo.title}</a>
                                    <a href="{:url('journal/joudel',['name'=>'diary','id'=>$vo.id])}" style="float:right;text-align:center;">删除</a>
                                    <span style="float:right">&nbsp;|&nbsp;</span>
                                    <a href="" style="float:right;text-align:center;">编辑</a>
                                    <span class="main_time">
                                        <?php echo date("Y-m-d",$vo['add_time']);?>
                                    </span>
                                </li>
                                {/volist}
                            </ul>
                        </div>
                    </div>
                </div>
                <!-- 私密日记结束 -->
            </div>
        </div>

        {include file='public/footer' /}
    </div>

    <script type="text/javascript">
        var rz = document.getElementById('rz');
        var myrz = document.getElementById('myrz');
        var rj = document.getElementById('rj');
        var myrj = document.getElementById('myrj');
        rz.onclick = function(){
            myrz.style.display="block";
            rz.className="main_bd";

            myrj.style.display="none";
            rj.className="";
        }
        rj.onclick = function(){
            myrj.style.display="block";
            rj.className="main_bd";

            myrz.style.display="none";
            rz.className="";
        }
    </script>
</body>
</html>